#pragma once
#ifndef skyPict_h__
#define skyPict_h__
#include "./skyAdapter.h"
#include "./skyImage.h"

#ifdef _SYMBIAN
#include "./symbian/symPict.h"
#elif defined(_GLES_)
#include "../adapter/gles/glPict.h"
#elif _DX90_
#include "../adapter/gles/glPict.h"
#endif

#include "./skyString.h"
#include "./skyBuffer.h"

namespace Sky
{
	

	class Pict : public OSPict
	{
		friend class PictManager;
	public:
		Pict(){};
		~Pict(){};
		StringPtr getName(){return _name;}
		Size getSize();
		
	protected:
		StringPtr _name;

	};
	typedef RefPtr<Pict> PictPtr;

	class PictManager : public OSPictManager
	{
	public:
		//typedef fastdelegate::FastDelegate2<MsgStatus, PictManager*, PictPtr*> Callback;
		typedef Bool (*Callback)();
		Bool createPictFromFile(String* file,Pict* pict,Callback doneCallback = vNull);
		Bool createPictFromBuffer(Buffer* buffer,Pict* pict,Callback doneCallback = vNull);
		Bool createPictFromRawBuffer(Buffer* buffer,Pict* pict,Callback doneCallback = vNull);
		
	};

	typedef RefPtr<PictManager> PictManagerPtr;
	
}
#endif // skyPict_h__
